//ES6的类
class Promise{
    constructor(executor){
        executor();
    }
    then(){}
    static resolve(){}
}
//转换成ES5
function Promise(executor){
    executor();
}
//类的实例属性转成ES5就是定义在类的原型上
Promise.prototype.then = ()=>{}
Promise.resolve=()=>{}
const executor = ()=>{}
let promise = new Promise(executor);